package com.strategy.example.demo.controller;

import com.strategy.example.demo.strategy.StrategyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author : spiderman
 * @version : 1.0
 * @FileName : com.strategy.example.demo.controller
 * @Description :
 * @Create Date : 2021/12/6 23:31
 **/
@RestController
@RequestMapping("/api/test")
public class StrategyController {

    @Autowired
    StrategyService strategyService;

    @RequestMapping("/get/{key}")
    public String get(@PathVariable String key) {
        return strategyService.getStrategy(key);
    }


}
